e01sef

e01sef © Numerical Algorithms Group, 2002.

Purpose

E01SEF Interpolating functions, modified Shepard's method, two variables

Synopsis

[fnodes,minnq,rnw,rnq,ifail] = e01sef(x,y,f<,nw,nq,rnw,rnq,ifail>)

Description

 
 This routine constructs an interpolating surface F(x,y) through a
 set of m scattered data points (x ,y ,f ), for r=1,2,...,m, using
                                  r  r  r                    
 a modification of Shepard's method. The surface is continuous and
 has continuous first derivatives.
 
 The basic Shepard method, interpolates the input data with the 
 weighted mean
 
                               m           
                               --          
                               >  w (x,y)f 
                               --  r      r
                               r=1         
                      F(x,y)= -------------,
                                m          
                                --         
                                >  w (x,y) 
                                --  r      
                                r=1        
 
                           1         2       2       2
            where w (x,y)= --  and  d =(x-x ) +(y-y ) .
                   r        2        r     r       r  
                           d                          
                            r                         
 
 The basic method is global in that the interpolated value at any 
 point depends on all the data, but this routine uses a 
 modification due to Franke and Nielson, whereby the method 
 becomes local by adjusting each w (x,y) to be zero outside a 
                                  r                
 circle with centre (x ,y ) and some radius R . Also, to improve 
                      r  r                   w        
 the performance of the basic method, each f  above is replaced 
                                            r         
 by a function f (x,y), which is a quadratic fitted by weighted 
                r                                     
 least-squares to data local to (x ,y ) and forced to interpolate 
                                  r  r               
 (x ,y ,f ). In this context, a point (x,y) is defined to be 
   r  r  r                                     
 local to another point if it lies within some distance R  of it. 
                                                         q
 Computation of these quadratics constitutes the main work done 
 by this routine. If there are less than 5 other points within 
 distance R  from (x ,y ), the quadratic is replaced by a linear 
           q        r  r                                 
 function. In cases of rank-deficiency, the minimum norm solution 
 is computed.
 
 The user may specify values for R  and R , but it is usually 
                                  w      q                   
 easier to choose instead two integers N  and N , from which the 
                                        w      q                
 routine will compute R  and R . These integers can be thought of 
                       w      q                                  
 as the average numbers of data points lying within distances R  
                                                               w
 and R  respectively from each node. Default values are provided.
 
 The interpolant F(x,y) generated by this routine can subsequently
 be evaluated for any point (x,y) in the domain of the data by a 
 call to E01SFF.
 

Parameters

e01sef

Required Input Arguments:

x (:)                                 real
y (:)                                 real
f (:)                                 real

Optional Input Arguments:                       <Default>

nw                                    integer  0
nq                                    integer  0
rnw                                   real     0
rnq                                   real     0
ifail                                 integer  -1

Output Arguments:

fnodes (:)                            real
minnq                                 integer
rnw                                   real
rnq                                   real
ifail                                 integer